package org.finesys.common.feign.config;

import org.finesys.common.feign.core.FeignHeaderRequestInterceptor;
import org.finesys.common.feign.core.FeignInnerRequestInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration(proxyBeanMethods = false)
public class FeignAutoConfiguration {

    /**
     * 增加内部请求头参数
     */
    @Bean
    public FeignInnerRequestInterceptor feignInnerRequestInterceptor() {
        return new FeignInnerRequestInterceptor();
    }

    /**
     * 请求头参数设置
     */
    @Bean
    public FeignHeaderRequestInterceptor feignHeaderRequestInterceptor() {
        return new FeignHeaderRequestInterceptor();
    }
}
